Generally, an electric discharge machine applies a preset voltage between a tool electrode attached to a main spindle and a workpiece attached to a working table and recognizes the positional relation between the tool electrode and the workpiece based on an electric current carried at the time of the contact between the tool electrode and the workpiece. The main spindle moves so as to make the tool electrode closer to the workpiece in a state where the voltage is applied between the tool electrode and the workpiece, and stops when it is recognized that the current flows between the tool electrode and the workpiece. A numerical control device recognizes a position at which it is recognized that the current flows between the tool electrode and the workpiece as a contact position between the tool electrode and the workpiece.
When an electric discharge phenomenon occurs before the tool electrode and the workpiece physically contact each other, then the numerical control device erroneously recognizes current-carrying resulting from the electric discharge phenomenon as the contact between the tool electrode and the workpiece, and it is difficult for the numerical control device to recognize the accurate positional relation between the tool electrode and the workpiece. As the applied voltage between the tool electrode and the workpiece is higher, the electric discharge phenomenon between the tool electrode and the workpiece tends to occur. To recognize the accurate positional relation between the tool electrode and the workpiece, it is considered to be desirable to suppress the electric discharge phenomenon by making the applied voltage between the tool electrode and the workpiece as low as possible, and to generate the current-carrying at a limit of the physical contact between the tool electrode and the workpiece.
For example, it is often difficult for a die-sinking electric discharge machine or the like to make the tool electrode directly contact the workpiece, depending on the shape of the tool electrode or the workpiece. In this case, the electric discharge machine often uses gauge heads called reference spheres while arranging the gauge heads at arbitrary positions of the main spindle and the workpiece, respectively. After carrying a current between the gauge heads in place of the tool electrode and the workpiece, the electric discharge machine performs the positioning of the workpiece based on the current carried between the gauge head attached to the main spindle and the workpiece and the positioning of the tool electrode based on the current carried between the gauge head attached to the workpiece and the tool electrode.
In recent years, the electric discharge machine is required to provide a more accurate positioning performance. The electric discharge machine tends to ensure the more accurate positional relation while suppressing the applied voltage between the tool electrode and the workpiece to a few volts to several tens of volts, for example. However, when foreign matters such as minute machining waste are attached onto the tool electrode, the workpiece or the gauge heads, current-carrying characteristics degrade as the electric resistance of the foreign matters is higher or the applied voltage is lower. When the foreign matters interpose in the contact between the tool electrode and the workpiece or between the gauge heads, flaws or impressions are often generated on the tool electrode, the workpiece or the gauge heads. At the low applied voltage, the current-carrying is possibly not detected until the physical contact starts because of the electric resistance of the material of the workpiece, the presence of thermal treatment or the like. In this case, similarly to the above case, flaws, impressions or the like are generated as a result of an excessive load given on the tool electrode, the workpiece or the gauge heads before the main spindle stops.
When a collision-caused impact occurs at the time of the physical contact between the tool electrode and the workpiece or between the gauge heads, an error is often generated in positional information due to transient response. Accordingly, after the current-carrying is detected, the main spindle often moves in an opposite direction to a moving direction in which the main spindle moves so far and the electric discharge machine performs an operation for detecting the contact based on the current-carrying again or repeatedly by an arbitrary number of times. At this time, when the moving velocity of the main spindle decelerates, the transient response-caused error can be reduced but the time required for the positioning operation increases. When the moving velocity of the main spindle accelerates, then vibration or elastic deformation is often generated depending on the shape or rigidity of the tool electrode, the workpiece or the gauge heads, and the accurate positional information cannot be often obtained. Therefore, appropriately limiting the moving velocity of the main spindle for the detection of the contact based on the current-carrying is considered to be also one of the objects of the electric discharge machine.
In recent years, a technique for detecting the interference of the tool electrode or the like by an overload on the main spindle is realized in the positioning operation performed by a wire electric discharge machine, a machine tool or the like that uses a wire as the tool electrode (see, for example, Patent Literature 1). The wire electric discharge machine, the machine tool or the like stops the subsequent positioning operation when detecting the overload, thereby suppressing damage on tools such as the tool electrode and the gauge heads, an apparatus main body and the workpiece. In the case of the die-sinking electric discharge machine, it is capable of suppressing the damage by allowing a worker to perform the positioning at an interference-free location because the worker is responsible for the positioning in many cases.